class CreatePhotos < ActiveRecord::Migration[5.0]
  def change
    create_table :photos do |t|
      t.belongs_to :user, index: true, comment: "关联用户"

      t.string     :file,              comment: "上传文件"
      t.timestamps
    end
  end
end
